﻿using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Dynamic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using CommunityToolkit.Mvvm.ComponentModel;

namespace WPFTechDemo
{
    public class MainWindowViewModel : ObservableObject
    {
        public MainWindowViewModel()
        {
            Companies = new ObservableCollection<Company>()
            {
                new()
                {
                    Name = "Microsoft",
                    Location = "Redmond",
                    Revenue = 1000000
                },
                new()
                {
                    Name = "Google",
                    Location = "Mountain View",
                    Revenue = 2000000
                },
                new()
                {
                    Name = "Apple",
                    Location = "Cupertino",
                    Revenue = 3000000
                },
                new()
                {
                    Name = "Amazon",
                    Location = "Seattle",
                    Revenue = 4000000
                },
                new()
                {
                    Name = "Facebook",
                    Location = "Menlo Park",
                    Revenue = 5000000
                },
            };
            SelectedCompanies = new ObservableCollection<Company>();
        }

        public ObservableCollection<Company> Companies { get; set; }
        public ObservableCollection<Company> SelectedCompanies { get; set; }
    }
}
